
package cz.czu.pef.DataModelling.service.impl;

import java.util.List;
import java.util.logging.Logger;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import cz.czu.pef.DataModelling.dao.*;
import cz.czu.pef.DataModelling.service.api.*;


@Service(value = "dataModellingService")
public class DataModellingServiceImpl implements DataModellingService
{

  Logger logger = Logger.getLogger(DataModellingServiceImpl.class.getName());

  @Autowired
  DataModellingDao dataModellingDao;

  @Transactional(propagation = Propagation.REQUIRED, readOnly = true)
  public List<Object[]> getAllMissingTrainings()
  {
    return dataModellingDao.getAllMissingTrainings();
  }

  @Transactional(propagation = Propagation.REQUIRED, readOnly = true)
  public List<Object[]> getAllMissingMedicalExaminations()
  {
    return dataModellingDao.getAllMissingMedicalExaminations();
  }

  @Override
  public List<Object[]> getAllMachineryWorkers()
  {
    return dataModellingDao.getAllMachineryWorkers();
  }
}
